﻿using System;
using System.Collections.Generic;
using System.Text;
using System.Drawing;
using System.Windows.Forms;

namespace VirtualVisionSpace
{
    /// <summary>
    /// 从环境中获取视觉数据
    /// </summary>
    /// <param name="region"></param>
    /// <returns></returns>
    public delegate Bitmap EnvironmentCallback(Rectangle region);

    /// <summary>
    /// 按一定频率输出视觉信息
    /// </summary>
    /// <param name="vision"></param>
    public delegate void VisionCallback(Bitmap vision);

    public interface IVision
    {
        EnvironmentCallback EnvironmentCallback { set; }

        VisionCallback VisionCallback { set; }

        Control DecodeShow { get; set; }

        /// <summary>
        /// 视觉区域
        /// </summary>
        Rectangle VisionRegion { get; set; }

        /// <summary>
        /// 刷新时间间隔
        /// </summary>
        double Interval { get; set; }

        void Start();

        void Stop();

        long RealEvnironmentElapsed { get; }
        long AvgEvnironmentElapsed { get; }

    }
}
